package com.jiyun.controller;

import com.jiyun.feign.QuestionFeign;
import com.jiyun.vo.ResponseBean;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("question")
public class QuestionController {
    @Resource
    private QuestionFeign questionFeign;

    /**
     * 根据试卷id查询问题
     * @param paperId
     * @return
     */
    @RequestMapping("findQuestionByPaperId")
    public ResponseBean findQuestionByPaperId(@RequestParam("paperId") Integer paperId){
        return questionFeign.findQuestionByPaperId(paperId);
    }
}
